Distributed ledger systems (DLSs), which can also be referred to as consensus networks, and/or blockchain networks, enable participating entities to securely, and immutably store data. DLSs are commonly referred to as blockchain networks without referencing any particular user case (e.g., crypto-currencies). Example types of blockchain networks can include public blockchain networks, private blockchain networks, and consortium blockchain networks. A public blockchain network is open for all entities to use the DLS, and participate in the consensus process. A private blockchain network is provided for particular entity, which centrally controls read and write permissions. A consortium blockchain network is provided for a select group of entities, which control the consensus process, and includes an access control layer.
Blockchains are used in crypto-currency networks, which enable participants to conduct transactions to buy/sell goods, and/or services using a crypto-currency. A common crypto-currency includes Bitcoin. In crypto-currency networks, record-keeping models are used to record transactions between users. Example record-keeping models include an unspent transaction output (UTXO) model, and account model (also referred to as account-based model or account/balance model).
In the UTXO model, the assets on the chain are in the form of transactions. Each transaction spends output from prior transactions and generates new outputs that can be spent in subsequent transactions. A user's unspent transactions are tracked, and a balance that the user has to spend is calculated as the sum of the unspent transactions. Each transaction takes one or more unspent outputs (and only unspent outputs) as input and can have one or more outputs. The requirement that only unspent outputs may be used in further transactions is necessary to prevent double spending and fraud. The UTXO model supports the transaction validation and proof function, but the support for smart contracts is weak.
The account model is adopted by Ethereum. The account model performs record-keeping and manages account balances like a traditional bank. Under this model, an account can have an address and a corresponding account balance. Assets on the chain are represented as the balance of the account. Each transfer transaction can have an account address of a transferred asset and an account address of a received asset. The transaction amount is directly updated on the balance of the account. The account model is efficient as each transaction may only need to validate that the sending account has enough balance to pay for the transaction. In addition to supporting the transaction validation and proof function, the account model can fully support smart contracts, especially those that require state information or involve multiple parties.